|
|
|
|
|
|
|
|
The controls shown in Figure 4.1 and described in Table 4.1 are not the only ones included with Visual Basic. To add other controls such as the Microsoft CommonDialog control or Microsoft FlexGrid control to the Toolbox, use the Components dialog box by choosing Project, Components, or right-clicking an empty area of the Toolbox and selecting Components from the context menu.  |
|
|
|
|
|
|
|
|
|
|
Many of the controls listed in Table 4.1 are discussed in the following sections. Others are described in chapters more closely associated with their purposes. The controls covered in other chapters are as follows: |
|
|
|
|
|
|
|
|
The PictureBox, Image, Shape, and Line controls are covered in Chapter 19, ''Using Visual Design Elements." |
|
|
|
|
|
|
|
|
The Data control is covered in Chapter 25, "The Data Control and Data-Bound Controls." |
|
|
|
|
|
|
|
|
The OLE control is covered in Chapter 22, "Using OLE to Control Other Applications." |
|
|
|
|
|
|
|
|
In Chapter 2, "Creating Your First Program," you built a simple program that used the TextBox and Label controls. If you have not read that chapter, you may want to review it before continuing. From the examples, you learned that the TextBox and Label controls are designed to work with text. The term text here does not just mean paragraphs and sentences like those you handle with a word processor. When you deal with text in a program, you also might want to display or retrieve a single word, a number, or even a date. You also may have noticed the major difference between the text box and label: the text box can be used both to display and accept text input, whereas the label control is designed for display-only use. Figure 4.2 shows various examples of TextBox and Label controls in use. |
|
|
|
|
|
|
|
|
Figure 4.2
Label controls identify the purposes of parts of this form, and text
boxes allow for the input or display of different types of information. |
|
|
|
|
|